﻿
using System;
namespace AspDIY.Net.Web
{
    /// <summary>
    ///PageBase 的摘要说明
    /// </summary>
    public class PageBase : System.Web.UI.Page
    {
        /// <summary>
        /// 当前页面标题
        /// </summary>
        protected internal string pagetitle = "页面";

        protected internal string siteurl = "/";
        protected internal string templatepath = "default";
        protected internal Config config = new Config();
        /// <summary>
        /// 页面内容
        /// </summary>
        protected internal System.Text.StringBuilder templateBuilder = new System.Text.StringBuilder();

        public PageBase()
        {
            //Config config = new Config();
            config.Title = pagetitle;
            config.Site = "我的网站";
            ShowPage();
            //
            //TODO: 在此处添加构造函数逻辑
            //
        }
        /// <summary>
        /// 页面处理虚方法
        /// </summary>
        protected virtual void ShowPage()
        {
            return;
        }
        /// <summary>
        /// 控件初始化时计算执行时间
        /// </summary>
        /// <param name="e"></param>
        protected override void OnInit(EventArgs e)
        {

            base.OnInit(e);
        }
    }
    [Serializable]
    public class Config
    {

        /// <summary>
        /// 当前标题
        /// </summary>
        public string Title;
        /// <summary>
        /// 网站名称
        /// </summary>
        public string Site;
    }
}
